The present invention relates generally to network switching communication protocols and in particular to the writing of descriptors.
A network switch creates a network among a plurality of end nodes, such as workstations, and other network switches connected thereto. Each end node is connected to one port of the network. The ports also serve to connect network switches together.
Each end node sends packets of data to the network switch which the switch then routes either to another of the end nodes connected thereto or to a network switch to which the destination end node is connected. In the latter case, the receiving network switch routes the packet to the destination end node.
Each network switch has to temporarily store the packets of data which it receives from the units (end node or network switch) connected to it while the switch determines how, when and through which port to retransmit the packets. Each packet can be transmitted to only one destination address (a xe2x80x9cunicastxe2x80x9d packet) or to more than one unit (a xe2x80x9cmulticastxe2x80x9d or xe2x80x9cbroadcastxe2x80x9d packet). For multicast and broadcast packets, the switch typically stores the packet only once and transmits multiple copies of the packet to some (multicast) or all (broadcast) of its ports. Once the packet has been transmitted to all of its destinations, it can be removed from the memory or written over.
Reference is now made to FIG. 1 which schematically illustrates a portion of the data packet transfer process that takes place within a network switch 10.
Switch 10 comprises a first memory 12 and a second memory 14, both of which are general function memories used to store data temporarily. Memory 14 is a random access memory and holds a plurality of data packets 16.
Memory 12 is a set of first-in-first-out (FIFOs) memories and comprises a multiplicity Q of output queues 18, each of which hold a plurality of descriptors 20. Each output queue 18 is dedicated to an associated end node.
Descriptors 20 are records which describe data packets 16; the description includes information such as buffer location, length of packet, transmitting information, etc. Descriptors 20 are unique per each associated data packet 16.
When a unicast data packet 16 is written into memory 14, one associated descriptor 20 is written into memory 12. When a multicast data packet 16 is written into memory 14, N descriptors 20 are written into memory 12, where N is the number of recipients of the multicast packet. Each of the N descriptors 20 is written into the appropriate output queue 18 for the designated end node.
The output queues 18 define the order with which the data packets will be written out, such that the descriptors 20 at the output end of each queue defines the next data packet to be transmitted.
Unfortunately accessing memory is time-consuming. To write each short descriptor into its appropriate output queue or queues requires multiple memory clock cycles, per write. This affects the overall speed of the network switch 10.
It is an object of the present invention to provide an faster method for writing descriptors than is found in the prior art.
There is therefore provided in accordance with a preferred embodiment of the present invention a method of writing descriptors, including the steps of writing into a local memory, wherein the local memory comprises a multiplicity of mini-queues, each mini-queue storing a plurality of descriptors, wherein each of the descriptors is associated with one of the data packets; accumulating the descriptors in the multiplicity of mini-queues; and transferring more than one of the descriptors from the multiplicity of queues to an output memory comprising a multiplicity of output queues, wherein each of the output queues in output memory is associated with one mini-queue in local memory.
There is therefore provided in accordance with a preferred embodiment of the present invention a device for writing descriptors, the device including a local memory comprising a multiplicity of mini-queues, wherein each of the mini-queues temporarily stores a plurality of descriptors, wherein each of the descriptors is associated with one of the data packets; and an output memory comprising a multiplicity of output queues, wherein each of the output queues in output memory is associated with one of the queues in said local memory, and a burst writer which writes N descriptors simultaneously from the mini-queue in the local memory to its associated output queue in output memory.